/**
 * Created by mapbar_front on 2019/8/2.
 */
import React,{Component} from 'react';
import Hoc1 from './../Hoc1';

class Hoc2 extends Component{
    constructor(props){
        super(props);
        // this.state = {
        //     value: '',
        // }
    }
    change=(e)=>{
        //console.log(e.target.value);
        // this.setState({
        //     value: e.target.value,
        // })
    }
    render() {
        console.log('Hoc2',{...this.props})
        return (
            <div>
                <h2>Hoc2</h2>
                <input type="text"
                       {...this.props}
                       //value={this.state.value}
                       //onChange={this.change}
                />
                <p>name：{this.props.name}</p>
                <p>age：{this.props.age}</p>
                <p>sex：{this.props.sex}</p>
            </div>
        )
    }
}
export default Hoc1(Hoc2);
